$(document).ready(function() {
	showClubValue();
});
function showMyClub(data) {
	var html = template('index', {
		data : data
	});
	$("#myMemorabilia").html(html);
}
function showClubValue() {
	$.ajax({
		url :localhost + "clubActivities/getCountIdAndTitle",
		dataType : "jsonp",
		jsonp : "jsonpCallback",
		success : function(data) {
			var str = "<option value =''></option>";
			for (var int = 0; int < data.length; int++) {
				str += '<option value ="' + data[int].club_activities_id + '">' + data[int].club_activities_title + '</option>'
			}
			$("#clubNameValue").html(str);
		}
	});
}
function showOne() {
	var clubActivitiesId = document.getElementById("clubNameValue").value;
	$.ajax({
		url :localhost + "clubActivities/getCountClubActivities",
		dataType : "jsonp",
		data : {clubActivitiesId : clubActivitiesId},
		jsonp : "jsonpCallback",
		success : function(data) {
			showMyClub(data);
		}
	});
}